<template>
  <div>
    <!-- 3.使用 -->
    <Top></Top>
    <Header @search="search"></Header>
    <Main></Main>
    <Footer></Footer>
  </div>
</template>


<script>
// 1.导入
import Top from './commons/top.vue'
import Header from './commons/header.vue'
import Main from './commons/main.vue'
import Footer from './commons/footer.vue'
export default{
  components:{
    // 2.注册
    Top,Header,Main,Footer
  },
  methods:{
    search(content){
      this.$router.push("/search/"+content)
    }
  }
}
</script>

<style scoped>

</style>